import Vue from 'vue'
import Router from 'vue-router'
import Info from '../view/website/info2'
import Layout from '../view/admin/layout/index'
import Role from '../view/admin/system/Role'
import Dict from '../view/admin/system/Dict'
import Cake from '../view/admin/cake/Cake'
import Stock from '../view/admin/cake/Stock'
import Index from '../view/website/Index'


Vue.use(Router)

export default new Router({
  routes: [
    {
      path: '/',
      name: 'Layout',
      component: Layout
    },{
         path:'/website/info',
         name:'Info',
         component:Info
    },{
      path:'/website/index',
      name:'Index',
      component:Index
    },{
          path:'/layout',
          name:'Layout',
          component:Layout
    },{
         path:'/system',
         name:'System',
         component:Layout,
         children:[
           {
              path:'role',
              name:'Role',
              component:Role
           },{
             path:'dict',
             name:'Dict',
             component:Dict
           }
         ]
    },{
      path:'/cake',
      name:'cake',
      component:Layout,
      children:[
        {
          path:'cake',
          name:'Cake',
          component:Cake
        },{
          path:'stock',
          name:'Stock',
          component:Stock
        }
      ]
    }
  ]
})
